// 5.8 Sentinels

#include <stdio.h>
int main() 
{
    #define CUTOFF 0
    float grade=0.01;
    float total=0;

    printf("\nTo stop entering grades, type in any negative number.\n\n");
   
    while (grade>=CUTOFF)
    {
        printf("Enter a grade: ");
        scanf("%f",&grade);
        total+=grade;              
    }

    printf("\nThe total of grades is %f\n",total-grade);
    
    return 0;
}